#ifndef DSPNASM_ADD_H
#define DSPNASM_ADD_H

#include <memory>
#include <vector>
#include "nasm/operand/operand.h"
#include "nasm/instruction/generator.h"
#include "nasm/instruction/instruction.h"

namespace dspnasm {
    class ADD : public Instruction {
    public:
        ADD() = default;

        ~ADD() override = default;

        static std::shared_ptr<ADD> genAddL(const std::bitset<4> &creg_z,
                                            const std::bitset<5> &dst,
                                            const std::bitset<5> &src2,
                                            const std::bitset<5> &src1,
                                            const std::bitset<1> &x,
                                            const std::bitset<7> &op,
                                            const std::bitset<1> &s,
                                            const std::bitset<1> &p);

        static std::shared_ptr<ADD> genAdd(const std::string &funcUnit,
                                           const std::vector<std::shared_ptr<Operand>> &ops, bool p);
    };
}

#endif //DSPNASM_ADD_H
